﻿@model RotaractProjectCalendar.Models.Club

@{
    ViewBag.Title = "Edycja";
}

<h2>Edycja</h2>

@using(Html.BeginForm("Edit", "Club", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
    @Html.AntiForgeryToken()

    <div class="form-horizontal">
        <h4>Klub</h4>
        <hr />
        @Html.ValidationSummary(true)
        @Html.HiddenFor(model => model.Id)

        <div class="form-group">
            @Html.LabelFor(model => model.ClubTitle, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.ClubTitle)
                @Html.ValidationMessageFor(model => model.ClubTitle)
            </div>
        </div>
        
        <dd>
            <img src="@Url.Content(Model.Logo)" class="img-circle img-responsive" alt="Project photo" width="300" />
        </dd>

        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="file" name="Attach" class=" btn btn-default" />
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.FbProfileAddress, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.FbProfileAddress)
                @Html.ValidationMessageFor(model => model.FbProfileAddress)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.WwwWebsiteAddress, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.WwwWebsiteAddress)
                @Html.ValidationMessageFor(model => model.WwwWebsiteAddress)
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.ClubEmailAddress, new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.ClubEmailAddress)
                @Html.ValidationMessageFor(model => model.ClubEmailAddress)
            </div>
        </div>

        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="submit" name="Edit" value="Zapisz" class="btn btn-default" />
            </div>
        </div>
    </div>
}

<div>
    @Html.ActionLink("Powrót", "Index")
</div>
